1. Field of the Invention
The present invention relates to a data decoder and a method of decoding data for decoding picture and voice bit stream data that is coded in accordance with the MPEG (Moving Picture Experts Group) standards.
2. Description of the Related Art
Among the standards which adopt the MPEG standards is the DVD standard. DVD presentation data is handled as program streams in the MPEG2 standard.
FIG. 1 shows an overview of a synchronous management control exercised by a DVD decoder.
The DVD decoder has an internal clock (reference clock) which is called STC (System Target Clock or System Time Clock). The DVD decoder operates the STC to count from zero concurrently with the start of reproduction. Meanwhile, the data recorded on a DVD has multiple PTSs (Presentation Time Stamps). The PTSs are information on the reproduction time for outputting (displaying or sounding) video data, audio data, and sub-picture data (closed caption data).
The DVD decoder starts the STC concurrently with the start of reproduction, and monitors the STC and the PTS periodically. When the STC and the PTS coincide with each other, the DVD decoder outputs the video data, the audio data, and the sub-picture data. While the DVD is reproduced normally, the PTS increases monotonously. Here, the DVD decoder starts the STC counting from zero as mentioned above, and sequentially reproduces bit stream data (frame data) that contains PTSs coincident with the STC.
In DVD playback, a deviation may occur between the PTS and the STC because of a pause, a fast-forward, etc. For example, between times Ta and Tb shown in FIG. 1, the PTS is delaying from the STC gradually (STC>PTS). This indicates a delay in the data reproduction. When the PTS is smaller than the STC, the DVD decoder discards a bit stream(s) to be decoded, thereby advancing the PTS to become coincident with the STC (time Tb). Between times Tc and Td, the PTS is getting ahead of the STC gradually (STC<PTS). This indicates that the data reproduction is quickening. When the PTS is greater than the STC, the DVD decoder temporarily holds the bit stream, thereby stopping the PTS forwarding so that the PTS and the STC coincide with each other (from the time Td to the time Te). Such an operation of making the PTS coincide with the STC is called a synchronous management control, which is indispensable to DVD players.
FIG. 2 shows an example of a DVD playback method of a DVD player.
DVD playback methods include (1) parental lock, (2) multi story, (3) multi angle, and (4) branching story. These playback methods are referred to as seamless playback. The seamless playback is a special playback technique unique to DVD for reproducing a plurality of different bit streams, as if they were a single bit stream, by virtually connecting them.
In this example, a continuous bit stream from VOBU#1 to VOBU#5 is recorded on the DVD. In addition, a bit stream VOBU#3′ is recorded on the DVD in a position different from that of VOBU#1-VOBU#5. Here, a VOBU (Video Object Unit) is a minimum unit of bit stream in the DVD standard. A VOBU contains video data, audio data, and sub-picture data, as well as navigation data (information for controlling reproduction) including PTSs. In the diagram, the hexadecimal numbers in the VOBU boxes represent the values of the PTSs.
The DVD decoder decodes bit streams on a VOBU basis for reproduction. Assume, for example, that the VOBU#3 includes a scene of violence. A parent who operates the DVD player shall keep the scene out of a child's sight, switching the VOBU#3 with the VOBU#3′, which includes a gentle scene, for reproduction (parental lock playback). VOBU#3′ is not continuous with VOBU#2, VOBU#3, or VOBU#4 in time. The PTS (0010h) of VOBU#3′ is different from the PTS (0030h) of VOBU#3. When VOBU#2, VOBU#3′, and VOBU#4 are reproduced in succession, the PTS at VOBU#3′ thus becomes discontinuous and smaller than the STC. Hereinafter, a point at which discontinuity of the PTS occurs will be referred to as gap (boundary). Moreover, the VOBUs locating prior and subsequent to a gap will be referred to as preceding VOBU and succeeding VOBU, respectively.
In the example shown in FIG. 2, the DVD decoder in the DVD player detects STC>PTS at VOBU#3′ under the synchronous management control as shown in FIG. 1, ending up with discarding the stream data. That is, VOBU#3′ will not be reproduced.
To avoid such a problem, it is necessary to stop the synchronous management control in the presence of a gap, and to forcefully store the value of the PTS of VOBU#3′ into the STC at the gap of the time Tg, the value of the PTS of VOBU#4 into the STC at the gap of the time Th. Such an intentional manipulation of the STC is called “STC gap processing” or simply “gap processing”.